/**
 * "Visual Paradigm: DO NOT MODIFY THIS FILE!"
 * 
 * This is an automatic generated file. It will be regenerated every time 
 * you generate persistence class.
 * 
 * Modifying its content may cause the program not work, or your work may lost.
 */

/**
 * Licensee: DuKe TeAm
 * License Type: Purchased
 */
package orm;

import org.hibernate.Criteria;
import org.orm.PersistentException;
import org.orm.PersistentSession;
import org.orm.criteria.*;

public class BabyMonitorCriteria extends AbstractORMCriteria {
	public final IntegerExpression codSystem;
	public final TimestampExpression regLogin;
	public final TimestampExpression regLogout;
	
	public BabyMonitorCriteria(Criteria criteria) {
		super(criteria);
		codSystem = new IntegerExpression("codSystem", this);
		regLogin = new TimestampExpression("regLogin", this);
		regLogout = new TimestampExpression("regLogout", this);
	}
	
	public BabyMonitorCriteria(PersistentSession session) {
		this(session.createCriteria(BabyMonitor.class));
	}
	
	public BabyMonitorCriteria() throws PersistentException {
		this(orm.Taller1PDSPersistentManager.instance().getSession());
	}
	
	public UserCriteria createUserCodUserCriteria() {
		return new UserCriteria(createCriteria("userCodUser"));
	}
	
	public DoctorCriteria createDoctoridDoctorCriteria() {
		return new DoctorCriteria(createCriteria("doctoridDoctor"));
	}
	
	public DiagnoseCriteria createDiagnoseCriteria() {
		return new DiagnoseCriteria(createCriteria("diagnose"));
	}
	
	public QuestFormCriteria createQuestFormCriteria() {
		return new QuestFormCriteria(createCriteria("questForm"));
	}
	
	public BabyMonitor uniqueBabyMonitor() {
		return (BabyMonitor) super.uniqueResult();
	}
	
	public BabyMonitor[] listBabyMonitor() {
		java.util.List list = super.list();
		return (BabyMonitor[]) list.toArray(new BabyMonitor[list.size()]);
	}
}

